package com.stylefeng.guns.modular.system.task;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.stylefeng.guns.core.util.DateUtil;
import com.stylefeng.guns.modular.system.dao.ParamsMapper;
import com.stylefeng.guns.modular.system.model.Params;
import com.stylefeng.guns.modular.system.service.IGpcService;

@Service
public class CurFengKouImportTask {

	@Autowired
	private IGpcService gpcService;
	
	@Autowired
	private ParamsMapper paramsMapper;
	
	public void execute(boolean isHoliday) {
		if(isHoliday){
			Params params = new Params();
			params.setgUserid("387065");
			params = paramsMapper.selectOne(params);
			if(params != null){
				gpcService.updateCurfk(DateUtil.getDay(), params.getgToken(),params.getgUserid());
			}
		}
	}
}
